﻿using Microsoft.VisualStudio.TestTools.UnitTesting;
using System;

[TestClass()]
public class UniversityTest
{
    [TestMethod]
    [ExpectedException (typeof(ArgumentException))]
    public void AddingAlreadyDefinedStudent()
    {
        string name = "Petur SUbev";
        int fn = 23236;
        Student pesho = new Student(name, fn);
        University tu = new University();
        tu.AddStudent(pesho);
        tu.AddStudent(pesho);
    }
    [TestMethod]

    public void StudentsCountProprerty()
    {
        string name = "Petur SUbev";
        int fn = 23236;
        Student pesho = new Student(name, fn);
        University tu = new University();
        tu.AddStudent(pesho);
        tu.AddStudent(new Student("Gosho",39091));
        Assert.AreEqual(2, tu.StudentsCount);
    }
}

